- page_title "Members"

- if membership_locked?
  .alert.alert-warning
    Adding new users is disabled at group level

.project-members-page.prepend-top-default
  - if can?(current_user, :admin_project_member, @project) && !membership_locked?
    .panel.panel-default
      .panel-heading
        Add new user to project
        .controls
          = link_to import_namespace_project_project_members_path(@project.namespace, @project), class: "btn btn-grouped", title: "Import members from another project" do
            Import members
      .panel-body
        %p.light
          Users with access to this project are listed below.
        = render "new_project_member"

    = render 'shared/members/requests', membership_source: @project, members: @project_members.request

  = render 'team', members: @project_members.non_request

  - if @group
    = render "group_members", members: @group_members

  - if @project_group_links.any? && @project.allowed_to_share_with_group?
    = render "shared_group_members"
